In here are the list of things I did for a particular hour or day. Also included here are the screenshots of games I played, or videos I watched or listened to, or just random things I stumbled upon. I'll occasionally write down what I'm thinking, or things I'm planning to do.
There fixed the __tostring problem by using L.CallByParam. I also had to create my own version of dofile since the one provided by gopher-lua doesn't allow setting the chunk name, and seeing chunk name is important when debugging.
I considered using htmz, but since hacker news doesn't have a lot of UI interactivity, it's not needed for this toy project.
I was wondering why I keep getting a nil pointer dereference, as it turns out, I'm closing L.close() before I could even use L. Now my problem is why the __tostring metamethod isn't being called from the go code. I'm currently looking for code examples how to do that, or just examples how to better use the gopher-lua API.
Worked on getting the lua environment to work with gopher-lua. The custom loader solution works fine, now I just to figure out a way to structure the web application. For demostration purposes, I'll just create a simple HN clone.
Oh, I see I what's going on here:
l(x) - b = f'(a)(x - a)
l(x) = f'(a)(x - a) + b
Is the book defining a function here? Or is it establishing an equation? This is actually quite confusing. In terms of programming, it would be like there's no separate syntax for defining functions from defining variables. You can't do that, is what I'm thinking, but math nerds are free to do what they want. But for my own clarity, I'll need to establish some conventions and a more rigid syntax when doing math.
What I want:
lol, I didn't realize my computer crashed, all input was unresponsive, but it was still playing the same tune 3 second tune in a loop. Oddly enough, it still quite catchy, so I didn't notice until I tried moving my mouse.
Anyway, I was on my notebook wondering what the geometric interpretation of negative exponents. n^m makes sense, it just multiplication. But what about n^-m, it's not apparent at first, but it's just equal division. What about n^(m^-1)? n^0.5 is square root, but what does that mean? Isn't that division as well? Maybe unequal division?
As it turns out, I don't really understand the basic, fundamentals of math. But why stop at multiplication and division. Maybe there's a weird arithmetic operator that has useful properties. Base-2 has `xor`, `nand` and other operators.
What if xor and others was generalized to arbitrary base? So instead of bit-wise pairing, on decimal, it would be digit pairing. What properties woud those operator have?
Can I define some weird operators too? Programmers after all do that all the time, well, haskell programmers do at least.
I will set aside these thoughts for now, I have a calculus book to read.
site last updated on 2024-10-16 | created with moontpl